/*----------------------------------------------------------------------------------------
*
*  Copyright 2019, Gao Hai Hui, <fromzeropoint@126.com>.  All rights reserved.
*  https://gitee.com/helloworldghh/xoskit.git
*  Use of this source code is governed by a MIT license
*  that can be found in the License file.
*
----------------------------------------------------------------------------------------*/
#ifndef __953F56A2_8EC0_4A6C_B87E_F5D2E6C2DAAD__
#define __953F56A2_8EC0_4A6C_B87E_F5D2E6C2DAAD__

namespace xos_common
{
    class i_common;
}

namespace xos_container
{
    // 
    // i_container interface
    // 
    class i_container : public xos::i_release
    {
    protected:
        virtual ~i_container(){}

    public:
        // str append
        virtual int str_append( char* lpszStr, int nBufSize, const char* lpszAdder, const char seperator = '/' ) = 0;

        // return obj
        virtual xos_aio::i_aio_mgr * aio() = 0;
        virtual xos_common::i_common * common() = 0;
        virtual xos_config::i_config * config() = 0;
        virtual xos_compress::i_compress_mgr * compress() = 0;
        virtual xos::i_xos * xos() = 0;
        virtual xos_curl::i_curl_mgr * curl() = 0;
        virtual xos_encrypt::i_encrypt_mgr * encrypt() = 0;
        virtual xos_http_protocol::i_http_mgr * http() = 0;
        virtual xos_json::i_json_mgr * json() = 0;
        virtual xos_log::i_log_mgr * log() = 0;
        virtual xos_net::i_net * net() = 0;
        virtual xos_box::i_box_mgr * box() = 0;
        virtual xos_odbc::i_odbc_mgr * odbc() = 0;
        virtual xos_package::i_package_mgr * package() = 0;
        virtual xos_sqlite::i_sqlite_mgr * sqlite() = 0;
        virtual xos_xml::i_xml_mgr * xml() = 0;

        // 常用对象，不需要释放
        virtual xos_common::i_misc * common_misc() = 0;
        virtual xos_log::i_log_file * log_file() = 0;
        virtual xos::i_misc * misc() = 0;
        virtual xos::i_crt * crt() = 0;
    };

    // 
    // export function for i_xos
    // 
    typedef int ( * f_create )( i_container ** ppv );
}

#endif // __953F56A2_8EC0_4A6C_B87E_F5D2E6C2DAAD__
